﻿using Newtonsoft.Json;

namespace Aquarinum.Base.Infrastructure.WebSocket.Dtos
{
    /// <summary>
    ///     用于客户端主动向服务端发送心跳，以判断是否断开连接
    /// </summary>
    public class ClinetHeartbeatDto : MessageBase
    {
        public ClinetHeartbeatDto()
        {
            Type = ConstSocketMessageType.CLINET_HEARTBEAT;
        }

        /// <summary>
        ///     仿造xmpp协议服务器域名
        /// </summary>
        [JsonProperty("domain")]
        public string Domain { get; set; }


        /// <summary>
        ///     仿造xmpp协议用户名
        /// </summary>
        [JsonProperty("user")]
        public string User { get; set; }

        /// <summary>
        ///     仿造xmpp协议属于用户的位置或设备，比如是手机还是电脑
        /// </summary>
        [JsonProperty("resource")]
        public string Resource { get; set; }

        /// <summary>
        ///     当前时间戳
        /// </summary>
        [JsonProperty("lasttimestamp")]
        public long Lasttimestamp { get; set; }
    }
}